package util;

import com.alibaba.fastjson.util.IOUtils;
import io.debezium.util.IoUtil;

import java.io.*;

/**
 * description
 * created by A on 2022/4/11
 */
public class IOUtilES {
    public String getContents(File path) throws IOException {
        FileInputStream fis=null;
        try{
            fis=new FileInputStream(path);
            String str = TikaUtil.tikaParse(fis);
            return str;
        } catch (FileNotFoundException e) {
            return "当前文件未去除水印";
        } finally {
            IOUtils.close(fis);
        }
    }

}
